package health.lm.com.order;

import android.os.Bundle;
import android.view.View;

import health.lm.com.component_base.base.mvp.activity.XActivity;
import health.lm.com.data.App;
import health.lm.com.router.ARouterConstant;

public class MainActivity extends XActivity {
    private String token = "yD9scYeJ8mhBtS3shXeIvd+m1p1ylXMD115tjA9i4o4/9kDz2HxgpxA2glonnUu3VwoZ+fBrIaC8qk4mxmDKu5WKO4k+34c2t2mKuxaWEfkBEHPHaXZy9qd1DkwqzKm/YLJXV5Zk+7GHOeN03w7ovw==";
    private String uid = "5346";
    @Override
    public int getLayoutId() {
        return R.layout.activity_main_order;
    }

    @Override
    public Object newP() {
        return null;
    }

    @Override
    public void initData(Bundle savedInstanceState) {
        App.getModel().setAccess_token(token);
        App.getModel().setUid(uid);
        //消费记录
        findViewById(R.id.pay_list).setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                gotoActivity(ARouterConstant.RecordsListActivity);
            }
        });
        //订单列表
        findViewById(R.id.order_list).setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                gotoActivity(ARouterConstant.OrderListActivity);
            }
        });
        //激活
        findViewById(R.id.jihuo).setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                gotoActivity(ARouterConstant.ActivationActivity);
            }
        });
        //扫码支付
        findViewById(R.id.pay_scan).setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                gotoActivity(ARouterConstant.SweepPayActivity);
            }
        });
        //活动支付
        findViewById(R.id.pay).setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                gotoActivity(ARouterConstant.ActivityPayActivity);
            }
        });
    }


}
